From 6968611fe10928b5c0afd4c093b6f4b597182381 Mon Sep 17 00:00:00 2001 From: Ashok Gautham Date: Wed, 20 Aug 2014 22:34:39 +0530 Subject: [PATCH] Print help message if cargo is invoked with no arguments --- src/bin/cargo.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/bin/cargo.rs b/src/bin/cargo.rs index b22a3a9ed..a5fa3ec16 100644 --- a/src/bin/cargo.rs +++ b/src/bin/cargo.rs @@ -87,9 +87,10 @@ fn execute(flags: Flags, shell: &mut MultiShell) -> CliResult> { args.as_slice(), false); cargo::process_executed(r, shell) }, - // If we have `help` with no arguments, re-invoke ourself with `-h` to - // get the help message printed - "help" if flags.arg_args.len() == 0 => { + // If we are invoked with no arguments or with `help` with no + // arguments, re-invoke ourself with `-h` to get the help + // message printed + "" | "help" if flags.arg_args.len() == 0 => { shell.set_verbose(true); let r = cargo::call_main_without_stdin(execute, shell, ["-h".to_string()], false); -- 2.30.2